<!--#include("hub_header.html")-->
	<!-- .pxeBody -->
	<div class="pxeBody">
		<div class="pxeContent">
			<div class="pxeCategory">
			        <form action="./" method="get"  class="DWsearchForm SearchForm">
				<!--@foreach($directories as $key => $val)-->
				<div class="section" style="width: {sprintf('%.2f%%', floor(100.0/(count($directories)+1)))}">
					<div data="{$key}" class="dirTitle"><a href="#" onclick="return false;" style="text-decoration:none;"><h2 >{$val->title}</h2></a></div>
					<ul class="dirUl_{$key}">
						<!--@foreach($val->childs as $k => $v)-->
						<li  data="{$key}_{$k}" class="shadow"|cond="$dirVal['dir_'.$key] == $k">
						    <a href="#" onclick="return false;">{$v->title} <em>({$v->count})</em></a>
						</li>
						<!--@end-->
					</ul>
					<input type="hidden" name="dir_{$key}" class="dir_{$key}" value="{$dirVal['dir_'.$key]}"/>
				</div>
				<!--@end-->
				<style>
				    .pxeCategory .section ul li a{text-decoration:none;color:#2465A9}
				    .pxeCategory .section ul li a:hover{text-decoration:underline;}
				    .shadow{background-color:#d8d8d8}
				    .shadow a{color:black}
				</style>
        <script type="text/javascript">
				    $ = jQuery;
				    $(function(){
    				      var formSubmit = function(eleObj)
    				      {
        				      var dataVal = $(eleObj).attr('data');
                             var arrData = dataVal.split('_');
                             if(arrData.length == 2)
                             {
                                 var dKey = arrData[0];
                                 var dVal = arrData[1];
                             }
                             else
                             {
                                 var dKey = dataVal;
                                 var dVal = '';
                             }
                             var dirObj = $('.dir_' + dKey);
                             dirObj.val(dVal);
                             $('.DWsearchForm').submit();
				          }
				          $('.dirTitle').click(function(){
				              formSubmit(this);
				          });
  				        $('.pxeCategory .section ul li').click(function(){
  				            formSubmit(this);
  				        });
				    });
				</script>
				<div class="section" style="width: {sprintf('%.2f%%', floor(100.0/(count($directories)+1)-1))}">
				<h2>Project Search</h2>
				<fieldset>
					<input name="keyword" type="text" title="{$lang->project_search}" class="iText" value="{$keyword}"/>
					<span class="btnPxe"><input name="" type="submit" value="{$lang->search}" /></span>
				</fieldset>
			        </div>
			        <input name="error_return_url" type="hidden" value=""/>
				</form>
			</div>
			<div class="pxeH">
				<h2>{$lang->total} <em>{$page_navigation->total_count}</em> {$lang->project_download}</h2>
				<div class="filter">
					<div class="select" style="width:200px;">
						<span class="ctrl"><span class="arrow"></span></span>
						<button type="button" class="myValue">{$lang->download_sort_order[$sort_order]}</button>
						<ul class="aList">
							<!--@foreach($lang->download_sort_order as $key=>$title)-->
							<li><a href="{getUrl('page','','sort_order',$key)}">{$title}</a></li>
							<!--@end-->
						</ul>
					</div>
				</div>
			</div>
			<table border="1" cellspacing="0" class="pxeT">
				<thead>
					<tr>
						<th scope="col"><span>{$lang->project_name}</span></th>
						<th scope="col"><span>{$lang->package_name}</span></th>
						<th scope="col"><span>{$lang->version}</span></th>
						<th scope="col" class="title"><span>{$lang->description}</span></th>
						<th scope="col" class="sort"><span>{$lang->download_count}</span></th>
						<th scope="col"><span>{$lang->uploaded_date}</span></th>
					</tr>
				</thead>
				<tbody>
					<!--@if(!$page_navigation->total_count)-->
					<tr>
						<td colspan="6" class="pxeNoData">
							<p>{$lang->no_relative_info}</p>
						</td>
					</tr>
					<!--@else-->
					<!--@foreach($project_list as $project)-->
					<tr>
						<td><a href="{getSiteUrl($project->domain)}">{$project->project_title}</a></td>
						<td><a href="{getSiteUrl($project->domain,'module','issuetracker','act','dispIssuetrackerDownload', 'package_srl', $project->package_srl)}">{$project->package_title}</a></td>
						<td><a href="{getSiteUrl($project->domain,'module','issuetracker','act','dispIssuetrackerDownload', 'release_srl', $project->release_srl)}">{$project->title}</a></td>
						<td class="title">{$project->release_note}</td>
						<td class="num sort">{$project->download_count}</td>
						<td class="num">{zdate($project->regdate, "Y.m.d")}</td>
					</tr>
					<!--@end-->
					<!--@end-->
				</tbody>
			</table>
			<div class="pagination">
                <!--@if($page_navigation->cur_page>1)--><a class="direction" href="{getUrl('page',1)}">&lsaquo; FIRST</a><!--@end-->
                <!--@if($page_navigation->cur_page>1)--><a class="direction" href="{getUrl('page',$page_navigation->cur_page-1)}">&lsaquo; PREV</a><!--@end-->
                <!--@while($page_no = $page_navigation->getNextPage())-->
                    <!--@if($page == $page_no)-->
                    <strong>{$page_no}</strong>
                    <!--@else-->
                    <a href="{getUrl('page',$page_no,'document_srl','','division',$division,'last_division',$last_division)}">{$page_no}</a>
                <!--@end-->
                <!--@end-->
                <!--@if($page_navigation->cur_page<$page_navigation->total_page)--><a class="direction" href="{getUrl('page',$page_navigation->cur_page+1)}">NEXT &rsaquo;</a><!--@end-->
                <!--@if($page_navigation->cur_page<$page_navigation->total_page)--><a class="direction" href="{getUrl('page',$page_navigation->total_page)}">END &rsaquo;</a><!--@end-->
			</div>
		</div>
	</div>
	<!-- /.pxeBody -->
</div>